package mjc.egg;
import mjc.compiler.*;
import mjc.gc.*;
import mg.egg.eggc.compiler.libjava.lex.*;
import mg.egg.eggc.compiler.libjava.messages.*;
import mg.egg.eggc.compiler.libjava.*;
import mg.egg.eggc.compiler.libjava.problem.IProblem;
import java.util.Vector;
public class S_PARFS_MJAVA {
LEX_MJAVA scanner;
  S_PARFS_MJAVA() {
    }
  S_PARFS_MJAVA(LEX_MJAVA scanner) {
    this.scanner = scanner;
    this.att_scanner = scanner;
    }
int [] sync= new int[0];
  Liste<Integer, INFOVar> att_param;
  Integer att_cle;
  TDS att_tds;
  LEX_MJAVA att_scanner;
  private void regle18() throws Exception {

    //declaration
    S_PARF_MJAVA x_3 = new S_PARF_MJAVA(scanner) ;
    S_PARFSX_MJAVA x_5 = new S_PARFSX_MJAVA(scanner) ;
    //appel
      action_ordreParam_18(x_3, x_5);
    x_3.analyser() ;
      action_trans_18(x_3, x_5);
    x_5.analyser() ;
      action_param1_18(x_3, x_5);
  }
  private void regle17() throws Exception {

    //declaration
    //appel
      action_init_17();
  }
private void action_init_17() throws Exception {
try {
// instructions
this.att_param=null;
this.att_cle=1;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
private void action_param1_18(S_PARF_MJAVA x_3, S_PARFSX_MJAVA x_5) throws Exception {
try {
// locales
// instructions
this.att_cle=1+x_5.att_cle;
    x_5.att_param.ajouter(x_5.att_cle+1, x_3.att_var);
this.att_param=x_5.att_param;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
private void action_trans_18(S_PARF_MJAVA x_3, S_PARFSX_MJAVA x_5) throws Exception {
try {
// instructions
x_5.att_tds=this.att_tds;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
private void action_ordreParam_18(S_PARF_MJAVA x_3, S_PARFSX_MJAVA x_5) throws Exception {
try {
// instructions
x_3.att_tds=this.att_tds;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
  public void analyser () throws Exception {
    scanner.lit ( 1 ) ;
    switch ( scanner.fenetre[0].code ) {
      case LEX_MJAVA.token_parf : // 66271
        regle17 () ;
      break ;
      case LEX_MJAVA.token_int : // 66284
        regle18 () ;
      break ;
      case LEX_MJAVA.token_bool : // 66285
        regle18 () ;
      break ;
      case LEX_MJAVA.token_void : // 66283
        regle18 () ;
      break ;
      case LEX_MJAVA.token_ident : // 66312
        regle18 () ;
      break ;
      default :
               scanner._interrompre(IProblem.Syntax, scanner.getBeginLine(), IMJAVAMessages.id_MJAVA_unexpected_token,MJAVAMessages.MJAVA_unexpected_token,new String[]{scanner.fenetre[0].getNom()});
    }
  }
  }
